Add type annotations for filename arguments
authorMatthias Clasen <mclasen@redhat.com>
Sat, 12 Jun 2021 15:12:06 +0000 (11:12 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Sat, 12 Jun 2021 15:12:06 +0000 (11:12 -0400)
Add missing "(type filename)" annotations for string
arguments that are filenames.

Fixes: #633
gdk/gdktexture.c
gsk/gskrendernode.c
gtk/gtkbookmarklist.c
gtk/gtkbuilder.c
gtk/gtkfilechooser.c
gtk/gtkmediafile.c
gtk/gtkpicture.c
gtk/gtkvideo.c

index 0332fca146fce97264a93529a34285bdb612e653..7ac4f1bb534a51ed074c05412c8c9834bc5ba66f 100644 (file)
@@ -533,7 +533,7 @@ gdk_texture_get_render_data (GdkTexture  *self,
 /**
  * gdk_texture_save_to_png:
  * @texture: a `GdkTexture`
- * @filename: the filename to store to
+ * @filename: (type filename): the filename to store to
  *
  * Store the given @texture to the @filename as a PNG file.
  *
index 7c442a760bcf558ceba6c0f4f7fc3c6489f09d11..24678978b83c7285b023cb10403ab06c7c1a2554 100644 (file)
@@ -562,7 +562,7 @@ gsk_render_node_diff (GskRenderNode  *node1,
 /**
  * gsk_render_node_write_to_file:
  * @node: a `GskRenderNode`
- * @filename: the file to save it to.
+ * @filename: (type filename): the file to save it to.
  * @error: Return location for a potential error
  *
  * This function is equivalent to calling gsk_render_node_serialize()
index 08bd5f1bb51e4c4026c3c4a3834dbfa8d2ada3fa..c947b25a4f591c5a73a0cb9b61353297490fd6a3 100644 (file)
@@ -452,7 +452,7 @@ gtk_bookmark_list_set_filename (GtkBookmarkList *self,
  * Returns the filename of the bookmark file that
  * this list is loading.
  *
- * Returns: the filename of the .xbel file
+ * Returns: (type filename): the filename of the .xbel file
  */
 const char *
 gtk_bookmark_list_get_filename (GtkBookmarkList *self)
@@ -464,7 +464,7 @@ gtk_bookmark_list_get_filename (GtkBookmarkList *self)
 
 /**
  * gtk_bookmark_list_new:
- * @filename: (nullable): The bookmark file to load
+ * @filename: (type filename) (nullable): The bookmark file to load
  * @attributes: (nullable): The attributes to query
  *
  * Creates a new `GtkBookmarkList` with the given @attributes.
index dd867fc3678a386eae35bbd43fc17262e6148846..ba31a8820ca66efec3e63d6e2395836a727ec738 100644 (file)
@@ -1175,7 +1175,7 @@ gtk_builder_new (void)
 /**
  * gtk_builder_add_from_file:
  * @builder: a `GtkBuilder`
- * @filename: the name of the file to parse
+ * @filename: (type filename): the name of the file to parse
  * @error: (nullable): return location for an error
  *
  * Parses a file containing a UI definition and merges it with
@@ -1245,7 +1245,7 @@ gtk_builder_add_from_file (GtkBuilder   *builder,
 /**
  * gtk_builder_add_objects_from_file:
  * @builder: a `GtkBuilder`
- * @filename: the name of the file to parse
+ * @filename: (type filename): the name of the file to parse
  * @object_ids: (array zero-terminated=1) (element-type utf8): nul-terminated array of objects to build
  * @error: (nullable): return location for an error
  *
@@ -2760,7 +2760,7 @@ gtk_builder_create_closure (GtkBuilder             *builder,
 
 /**
  * gtk_builder_new_from_file: (constructor)
- * @filename: filename of user interface description file
+ * @filename: (type filename): filename of user interface description file
  *
  * Parses the UI definition in the file @filename.
  *
index 44931a54dca8a2d5661fe7a32f8e30a6cadb3757..c472e115db3a4bd2893afe1e0661a657113c8784 100644 (file)
@@ -459,7 +459,7 @@ gtk_file_chooser_get_files (GtkFileChooser *chooser)
  * the file’s base name will also appear in the dialog’s file name entry.
  *
  * If the file name isn’t in the current folder of @chooser, then the current
- * folder of @chooser will be changed to the folder containing @filename.
+ * folder of @chooser will be changed to the folder containing @file.
  *
  * Note that the file must exist, or nothing will be done except
  * for the directory change.
index 079e1b367d558ad2d2cddfdbe81931a3af6dc09f..96e8c847318232d240083342111397eeb5a72145 100644 (file)
@@ -270,7 +270,7 @@ gtk_media_file_new (void)
 
 /**
  * gtk_media_file_new_for_filename:
- * @filename: filename to open
+ * @filename: (type filename): filename to open
  *
  * Creates a new media file for the given filename.
  *
@@ -420,7 +420,7 @@ gtk_media_file_clear (GtkMediaFile *self)
 /**
  * gtk_media_file_set_filename:
  * @self: a `GtkMediaFile`
- * @filename: (nullable): name of file to play
+ * @filename: (type filename) (nullable): name of file to play
  *
  * Sets the `GtkMediaFile to play the given file.
  *
index 194d2fc98abba844a3241b0ba70d21fc6eab2cac..7694888c68483e4db91248c6221e6b47f02c47d2 100644 (file)
@@ -619,7 +619,7 @@ gtk_picture_get_file (GtkPicture *self)
 /**
  * gtk_picture_set_filename:
  * @self: a `GtkPicture`
- * @filename: (nullable): the filename to play
+ * @filename: (type filename) (nullable): the filename to play
  *
  * Makes @self load and display the given @filename.
  *
index 2343a3aba9f4894bbd0973d14296bf8e0b64798b..85b13fe9a9ff0125e9b720b8bd0430c1f28f3fdf 100644 (file)
@@ -714,7 +714,7 @@ gtk_video_set_file (GtkVideo *self,
 /**
  * gtk_video_set_filename:
  * @self: a `GtkVideo`
- * @filename: (nullable): the filename to play
+ * @filename: (type filename) (nullable): the filename to play
  *
  * Makes @self play the given @filename.
  *